package org.springframework.aop.interceptor;

import org.springframework.aop.MethodBeforeAdvice;

import java.lang.reflect.Method;
import java.util.Arrays;

/**
 * @Name ABeforeAdvice
 * @Description: A 目标方法前置通知 [处理] 类
 * @Version v1.0.0
 * @Author: lichao
 * @Date: 2024-04-12 15:30:05
 **/
public class ABeforeAdvice implements MethodBeforeAdvice {
    @Override
    public void before(Method method, Object[] args, Object target) throws Throwable {
        System.out.println("目标对象 -> " + target);
        System.out.println("目标方法 -> " + method.getName());
        System.out.println("目标方法入参: " + Arrays.toString(args));
        System.out.println("执行前置处理逻辑... ...");
    }
}

